package com.lanyuan.a.bean;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.annotations.GenericGenerator;

@Entity
@Table(name="ly_store")
public class Store {
	private int id;
	private int w_f_id;
	private int w_id;
	private String name;
	private String desc;
	private double cost;
	private double price;
	private int total;
	private int left;
	
	@Id
	@GenericGenerator(name = "generator", strategy = "native")
	@GeneratedValue(generator = "generator")
	@Column(name = "id", length = 20)
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}
	@Column(name = "names", length = 20)
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	@Column(name = "descs", length = 20)
	public String getDesc() {
		return desc;
	}
	public void setDesc(String desc) {
		this.desc = desc;
	}
	@Column(name = "cost", length = 20)
	public double getCost() {
		return cost;
	}
	public void setCost(double cost) {
		this.cost = cost;
	}
	@Column(name = "price", length = 20)
	public double getPrice() {
		return price;
	}
	public void setPrice(double price) {
		this.price = price;
	}
	@Column(name = "total", length = 20)
	public int getTotal() {
		return total;
	}
	public void setTotal(int total) {
		this.total = total;
	}
	@Column(name = "lefts", length = 20)
	public int getLeft() {
		return left;
	}
	public void setLeft(int left) {
		this.left = left;
	}
	@Column(name = "w_id", length = 20)
	public int getW_id() {
		return w_id;
	}
	public void setW_id(int w_id) {
		this.w_id = w_id;
	}
	@Override
	public String toString() {
		return "Store [id=" + id + ", w_id=" + w_id + ", name=" + name
				+ ", desc=" + desc + ", cost=" + cost + ", price=" + price
				+ ", total=" + total + ", left=" + left + "]";
	}
	@Column(name = "w_f_id", length = 20)
	public int getW_f_id() {
		return w_f_id;
	}
	public void setW_f_id(int w_f_id) {
		this.w_f_id = w_f_id;
	}
	public Store(int id, int w_f_id, int w_id, String name, String desc,
			double cost, double price, int total, int left) {
		super();
		this.id = id;
		this.w_f_id = w_f_id;
		this.w_id = w_id;
		this.name = name;
		this.desc = desc;
		this.cost = cost;
		this.price = price;
		this.total = total;
		this.left = left;
	}
	public Store() {
		super();
	}
	
	
}
